[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
shr Bitwise Right-Shift Integer Operator [TP]
<exp1> shr <exp2>
SHR does a bitwise right-shift on <exp1>, shifting it <exp2> places to
the right and filling with zeros. The result is a 16-bit integer
value. Note that if <exp1> is negative and <exp2> is greater than
zero, then the resulting expression will be positive. Shifting an
unsigned number right is the same as dividing it by 2 for every bit
shifted right.
<exp1> Any integer expression.
<exp2> Any integer expression. Note that if <exp2> is greater
than 15 or less than 0, the resulting value will
always be zero.
-------------------------------- Example ---------------------------------
I := 25 shr 1; { I = 12 }
I := $4123 shr 8; { I = $0041 }
See Also:
shl
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson